import { View } from '@tarojs/components';

const ICON_MAP = {
  primary:
    'https://applets-1302975996.cos.ap-nanjing.myqcloud.com/zhb/icon-status-primary.svg',
  success:
    'https://applets-1302975996.cos.ap-nanjing.myqcloud.com/zhb/order-bar-status-success.svg',
  warning:
    'https://applets-1302975996.cos.ap-nanjing.myqcloud.com/zhb/order-bar-status-paid.svg',
  cancel:
    'https://applets-1302975996.cos.ap-nanjing.myqcloud.com/zhb/order-bar-status-cancel.svg',
};
export default function StatusIconPrimary(props?: {
  color?: 'primary' | 'success' | 'warning' | 'cancel';
}) {
  return (
    <View
      className='w-[170px] h-[36px] bg-cover mr-auto'
      style={{
        backgroundImage: `url(${ICON_MAP[props?.color || 'primary']})`,
      }}
    />
  );
}
